package com.smooth.site.sx.pc.base.rsp;

import java.util.ArrayList;
import java.util.List;

import org.apache.commons.beanutils.BeanUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.smooth.dao.gen.bean.BaseSchSubject;

public class BaseSchSubjectRsp extends BaseSchSubject {
	static Logger log = LoggerFactory.getLogger(BaseSchSubjectRsp.class);
	private String showName;

	public String getShowName() {
		return showName;
	}

	public void setShowName(String showName) {
		this.showName = showName;
	}
	
	public static List<BaseSchSubjectRsp> getRsp(List<BaseSchSubject> sbList) {
		
		List<BaseSchSubjectRsp> rlist = new ArrayList<>();
		for(BaseSchSubject baseSchSubject : sbList) {
			BaseSchSubjectRsp baseSchSubjectRsp = new BaseSchSubjectRsp();
			
			try{
				BeanUtils.copyProperties(baseSchSubjectRsp, baseSchSubject);
			}catch(Exception e) {
				log.error("",e);
			}
			baseSchSubjectRsp.setShowName(baseSchSubject.getSubName());
			
			rlist.add(baseSchSubjectRsp);
		}
		return rlist;
	}
}
